<%@ page language="java" contentType="text/html; charset=UTF-8"	pageEncoding="UTF-8"%>
<%@ include file="../common/include.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>物品</title>

<script type="text/javascript">
	$(document).ready(function() {
		showCategory($("#categoryId"));
	});
	
	function f_treeDblClick(node){
		f_afterClick(node);
	}
	function f_afterClick(node){
		$("#categoryId").attr("value",node.attr("id"));
		$("#cname").text($('span:first',node).text());
	}
</script>
 
</head>
<body>
<div id="head"><jsp:include page="../common/head.jsp"/></div>
	<div id="body">
	<div id="left">
		<div><jsp:include page="../common/left.jsp"/></div>
		<div></div>
	</div>
	<div id="right"><div>

<div>${msg }</div>
<jsp:include page="box/categorylist.jsp"></jsp:include>
<form:form commandName="bGoods">
<table>
<thead>
</thead>
<tbody>
<tr><td>所属父类</td><td>
<form:input path="categoryId" readonly="true"/><span id="cname" ></span> <form:errors class="error" path="categoryId" />
</td>
</tr>
<tr><td>名称</td><td>
<form:input path="name"/><form:errors class="error" path="name" />
</td>
</tr>
<tr><td>规格</td><td><form:input path="specification"/>  <form:errors class="error" path="specification" /> </td>
</tr>
<tr><td>单位</td><td>
<form:select path="unitId" items="${unit}"></form:select><form:errors class="error" path="unitId" /></td>
</tr>
<tr><td>备注</td><td><form:input path="notes" />  <form:errors class="error" path="notes" /> </td>
</tr>
</tbody>
<tfoot><tr><td><button type="submit">提交</button>  </td>
</tr></tfoot>
</table>
</form:form>


</div></div>
</div>


</body>
</html>